import 'package:flutter/material.dart';
import 'dart:async';

class LoadingPapge extends StatefulWidget{
  @override 
  _LoadingState createState() => new _LoadingState();
}

class _LoadingState extends State<LoadingPapge>{

  @override 
  void initState(){
    super.initState();
    new Future .delayed(Duration(seconds: 3),(){
      print("Flutter即时通讯APP页面实现。。。");
      Navigator.of(context).pushReplacementNamed("app");
    });
  }

  @override 
  Widget build(BuildContext context){
    return new Center(
      child: Stack(
        children: <Widget>[
          Image.asset("images/loading.jpeg",fit: BoxFit.cover,),
        ],
      ),
    );
  }
}